package com.example.demo.Common.Enum;

import com.baomidou.mybatisplus.annotation.EnumValue;
import com.fasterxml.jackson.annotation.JsonValue;

public enum RoleType{
    customer(1,"顾客"),
    admin(2,"管理员");

    /** 数据库存储数据 */
    @EnumValue
    private final Integer value;
    /** 显示文本 */
    @JsonValue
    private final String role;

    RoleType(Integer value, String role) {
        this.value = value;
        this.role = role;
    }
}
